CONTENTS | INDEX | PREV | NEXT
CreateDiceRexxPort
FUNCTION
Create an application ARexx port (DICE)
SYNTAX
#include <lib/rexx.h>
short r = CreateDiceRexxPort(port, name)
struct MsgPort *port;
char *name;
DESCRIPTION
This call integrates any number of ARexx ports beyond the master port
into DICE's ARexx system. This call may be made from any point in
your program. After this call returns the message port will accept
incomming ARexx messages.
|| NOTE: For simple programs you can simply use the master port
|| (RexxPort) that DICE sets up for you automatically and need not
|| bother with creating additional ports. This call is more of use
|| in more complex programs which handle multiple projects
|| simultaniously.
If you had declared RexxHostName as NULL causing DICE to not
initialize an internal default RexxPort, you can pass NULL for port
to initialize DICE's internal default RexxPort, thereby allowing
PlaceRexxCommand() calls that specify a NULL port (i.e. to use DICE's
internal default RexxPort). You are not required to use DICE's
internal message port, it is simply convenient.
INPUTS
struct MsgPort *port;
A blank msgPort structure (that is, totally
zero'd out). DICE will fill the structure with
appropriate values. DICE uses the same signal bit
as it allocated for the master port (RexxPort).
DICE makes this message port public through the
AddPort() call.
char *name A pointer to the name of the message port. DICE
adds a .NN extension to this name, finding a free
slot number when creating a public message port.
If you pass NULL for this field, DICE will create
a private message port suitable for handling
ARexx call-backs. An error (-1) is returned if
no slots are available (all 99 are in use). If
you had passed NULL for the port structure then
DICED will initialize RexxHostName to the
extended name.
RESULTS
int r; the slot number for the port or -1 if an error occured.